package com.csair.youth.database.base;

import java.io.Serializable;


/**
 * This is an object that contains data related to the notice table.
 * Do not modify this class because it will be overwritten if the configuration file
 * related to this class is modified.
 *
 * @hibernate.class
 *  table="notice"
 */

public abstract class BaseNotice  implements Serializable {

	public static String REF = "Notice";
	public static String PROP_PUBLISH_TIME = "PublishTime";
	public static String PROP_LAST_MODIFY_TIME = "LastModifyTime";
	public static String PROP_PUBLISH_IP = "PublishIp";
	public static String PROP_ID = "Id";
	public static String PROP_PUBLISH_USER_ID = "PublishUserId";
	public static String PROP_LAST_MODIFY_IP = "LastModifyIp";
	public static String PROP_LAST_MODIFY_USER_ID = "LastModifyUserId";
	public static String PROP_CONTENT = "Content";
	public static String PROP_TITLE = "Title";


	// constructors
	public BaseNotice () {
		initialize();
	}

	/**
	 * Constructor for primary key
	 */
	public BaseNotice (java.lang.String id) {
		this.setId(id);
		initialize();
	}

	/**
	 * Constructor for required fields
	 */
	public BaseNotice (
		java.lang.String id,
		java.lang.String title,
		java.lang.String content,
		java.lang.String publishUserId,
		java.lang.String publishIp,
		java.util.Date publishTime,
		java.lang.String lastModifyUserId,
		java.lang.String lastModifyIp,
		java.util.Date lastModifyTime) {

		this.setId(id);
		this.setTitle(title);
		this.setContent(content);
		this.setPublishUserId(publishUserId);
		this.setPublishIp(publishIp);
		this.setPublishTime(publishTime);
		this.setLastModifyUserId(lastModifyUserId);
		this.setLastModifyIp(lastModifyIp);
		this.setLastModifyTime(lastModifyTime);
		initialize();
	}

	protected void initialize () {}



	private int hashCode = Integer.MIN_VALUE;

	// primary key
	private java.lang.String id;

	// fields
	private java.lang.String title;
	private java.lang.String content;
	private java.lang.String publishUserId;
	private java.lang.String publishIp;
	private java.util.Date publishTime;
	private java.lang.String lastModifyUserId;
	private java.lang.String lastModifyIp;
	private java.util.Date lastModifyTime;



	/**
	 * Return the unique identifier of this class
     * @hibernate.id
     *  generator-class="uuid.hex"
     *  column="ID"
     */
	public java.lang.String getId () {
		return id;
	}

	/**
	 * Set the unique identifier of this class
	 * @param id the new ID
	 */
	public void setId (java.lang.String id) {
		this.id = id;
		this.hashCode = Integer.MIN_VALUE;
	}




	/**
	 * Return the value associated with the column: TITLE
	 */
	public java.lang.String getTitle () {
		return title;
	}

	/**
	 * Set the value related to the column: TITLE
	 * @param title the TITLE value
	 */
	public void setTitle (java.lang.String title) {
		this.title = title;
	}



	/**
	 * Return the value associated with the column: CONTENT
	 */
	public java.lang.String getContent () {
		return content;
	}

	/**
	 * Set the value related to the column: CONTENT
	 * @param content the CONTENT value
	 */
	public void setContent (java.lang.String content) {
		this.content = content;
	}



	/**
	 * Return the value associated with the column: PUBLISH_USER_ID
	 */
	public java.lang.String getPublishUserId () {
		return publishUserId;
	}

	/**
	 * Set the value related to the column: PUBLISH_USER_ID
	 * @param publishUserId the PUBLISH_USER_ID value
	 */
	public void setPublishUserId (java.lang.String publishUserId) {
		this.publishUserId = publishUserId;
	}



	/**
	 * Return the value associated with the column: PUBLISH_IP
	 */
	public java.lang.String getPublishIp () {
		return publishIp;
	}

	/**
	 * Set the value related to the column: PUBLISH_IP
	 * @param publishIp the PUBLISH_IP value
	 */
	public void setPublishIp (java.lang.String publishIp) {
		this.publishIp = publishIp;
	}



	/**
	 * Return the value associated with the column: PUBLISH_TIME
	 */
	public java.util.Date getPublishTime () {
		return publishTime;
	}

	/**
	 * Set the value related to the column: PUBLISH_TIME
	 * @param publishTime the PUBLISH_TIME value
	 */
	public void setPublishTime (java.util.Date publishTime) {
		this.publishTime = publishTime;
	}



	/**
	 * Return the value associated with the column: LAST_MODIFY_USER_ID
	 */
	public java.lang.String getLastModifyUserId () {
		return lastModifyUserId;
	}

	/**
	 * Set the value related to the column: LAST_MODIFY_USER_ID
	 * @param lastModifyUserId the LAST_MODIFY_USER_ID value
	 */
	public void setLastModifyUserId (java.lang.String lastModifyUserId) {
		this.lastModifyUserId = lastModifyUserId;
	}



	/**
	 * Return the value associated with the column: LAST_MODIFY_IP
	 */
	public java.lang.String getLastModifyIp () {
		return lastModifyIp;
	}

	/**
	 * Set the value related to the column: LAST_MODIFY_IP
	 * @param lastModifyIp the LAST_MODIFY_IP value
	 */
	public void setLastModifyIp (java.lang.String lastModifyIp) {
		this.lastModifyIp = lastModifyIp;
	}



	/**
	 * Return the value associated with the column: LAST_MODIFY_TIME
	 */
	public java.util.Date getLastModifyTime () {
		return lastModifyTime;
	}

	/**
	 * Set the value related to the column: LAST_MODIFY_TIME
	 * @param lastModifyTime the LAST_MODIFY_TIME value
	 */
	public void setLastModifyTime (java.util.Date lastModifyTime) {
		this.lastModifyTime = lastModifyTime;
	}




	public boolean equals (Object obj) {
		if (null == obj) return false;
		if (!(obj instanceof com.csair.youth.database.Notice)) return false;
		else {
			com.csair.youth.database.Notice notice = (com.csair.youth.database.Notice) obj;
			if (null == this.getId() || null == notice.getId()) return false;
			else return (this.getId().equals(notice.getId()));
		}
	}

	public int hashCode () {
		if (Integer.MIN_VALUE == this.hashCode) {
			if (null == this.getId()) return super.hashCode();
			else {
				String hashStr = this.getClass().getName() + ":" + this.getId().hashCode();
				this.hashCode = hashStr.hashCode();
			}
		}
		return this.hashCode;
	}


	public String toString () {
		return super.toString();
	}


}